Load Balanced Profiling

ABSTRACT

A conventional load regulator ( 2 ) and a profiling tool ( 1 ) are provided with an added functionality to dynamically: balance the profiling performance of the profiling tool with the available spare CPU capacity in a system, e.g. a telecommunication system, using a communicating interface. The load regulator regularly sends ( 504, 514 ) information to the profiling tool of any spare CPU capacity during profiling, and the profiling tool adjusts ( 512 ) the performance of the profiling gradually, in response to the received information.

TECHNICAL FIELD

The present invention relates to a method of profiling in a loadregulator and in a profiling tool of a system, and to a load regulatorand a profiling tool.

BACKGROUND

In order to evaluate the behaviour and performance of a computer systemor a telecommunication system in real time and at different workloads, aso-called profiling tool may monitor the system performance and conducta performance analysis in order to obtain the desired profileinformation. Such a profiling tool, i.e. a profiler, is capable ofrecording information at specific points of time or at specific eventsand of displaying the profile information, e.g. as a stream of recordedsample information or as a statistical summary.

The profiling information collected by a profiling tool is essential forthe system characterization, and for enabling improvements in detailsand in the overall performance, as well as for identifying specificperformance-related problems. However, some real time systems are notprovided with any profiling capability at all, and some profiling toolsmay be unreliable or may need to be operated by a specialist in order toavoid disturbances, of the real-time system, and a corresponding reducedsystem performance. Other known profiling tools have a limitedcontrollability and a low detail level of the collected information, inorder to achieve reliability and a low performance-impact.

A suitable implementation of recording information for real-timeprofiling may comprise an interruption of the execution of a runningprogram code at regular sampling intervals or at certain events, andconventional techniques for profiling include sampling techniques andinstrumentation techniques, of which the sampling technique normally ismore suitable for real-time profiling than instrumentation techniques.

Sampling techniques involve an interruption of the execution and acollection of data, and may be subdivided into periodic instructionprofiling and event profiling, of which instruction profiling performsinterruptions with specific time intervals to approximate a randombehaviour, while event profiling interrupts the execution and collectionof data at specific events. The instruction profiling is non-intrusive,and a reliable profile can be obtained comparatively quickly, and it maye.g. be used to obtain a profile of which part of a code that aprocessor executes the most by interrupting the execution periodically,with a certain sampling interval, and saving the instruction address.

The event profiling is also non-intrusive, but it takes longer to obtaina reliable profile. Event profiling may e.g. be used to obtain a profileof cache misses by interrupting the execution at every 1000 cache missand recording the address and the time interval between theseinterruptions.

The capacity overhead caused by sampling profiling can be controlled byselecting an appropriate length of the sampling intervals, but it willalso depend on the amount of collected information.

However, in event profiling techniques, only a few different andpredefined parameters can be sampled, which may limit the profile. Insampling profiling, events may be missed if they do not occur in asampling moment, which makes it unsuitable for obtaining a profile ofthe occurrence of rare events.

The instrumentation techniques may be subdivided into static and dynamicinstrumentation, and static instrumentation involves instrumenting abinary code with added instructions for saving profiling information,e.g. each instruction that changes the control flow and causes a jump inthe code to save the target address, in order to obtain a profile ofwhich parts of the coded that is executed the most. By means ofinstrumentation profiling, a more detailed and complete information canbe collected regarding individual instructions, a jump or a variableaccess. However, it consumes more capacity resulting in a largeprofiling capacity overhead, and a detailed instrumentation may slowdown the system 10 times or more. Therefore, in order to achieve a loweroverhead, the instrumentation must be limited to only a small fractionof the code, or be less detailed, which makes it unsuitable for realtime systems. Further, two versions of the code will exist, theproduction method and the instrumented version, requiring switchingbetween the two versions.

The conventional dynamic instrumentation is the latest and the mostadvanced profiling, method, and it may be programmable to enable anapplication specific profiling. A dynamic instrumentation tool insertsinstrumentation points by replacing an instruction with a jump to apatch area, thereby achieving a dynamic modification of theinstructions. The patch area comprises data associated with eachinstrumentation point, including instructions to be executed regardingthe profiling, as well as instructions to return to the instrumentationpoint.

A dynamic instrumentation tool is capable of collecting both overallinformation and detailed information, and may be used interactively tofirst obtain a profile regarding an overall picture and thereafter toobtain a detailed profile regarding specific parts of said overallpicture. Further, it is capable of safe collection of all occurrences ofcertain events, and is thereby suitable for obtaining a profile of rareevents. However, a drawback of dynamic instrumentation is the largecapacity overhead and that the size of this overhead can not beguaranteed, i.e. there is no guaranteed maximum capacity overhead.Additionally, the overhead is difficult to calculate, since it dependsboth on the profiling instruction and how often it is triggered, whichmay be unknown.

Related art within the technical field is further disclosed e.g. in theU.S. Pat. No. 5,689,636 and U.S. Pat. No. 5,794,011. U.S. Pat. No.5,689,636 describes a real-time tracing system which causes a dynamicload, which is monitored by the tracing system itself. The tracingsystem also deactivates itself when this dynamic load exceeds a certainthreshold value. A trace differs from a profile in that it represents acomplete record of the steps executed of a program, while a profile isonly a statistical display of a collection of selected events. U.S. Pat.No. 5,794,011 describes a performance regulating program for externalunits of a real-time system, and the program monitors and controls theperformance level of the external units in order to avoid overload.

A conventional load regulating system in e.g. a telecommunication systemsupervises the system load and controls the traffic in order to avoidoverload situations, which will lead to long delays and time-outs. Atypical function of a telecommunication system load regulating functionis to reject new calls before overload occurs when the load reaches, apredetermined limit, i.e. the maximum loadability. Thereby, the systemwill avoid overload, and use its capacity to handle real traffic insteadof handling emergency tasks caused by overload. A computer controlsystem is normally designed with different task priorities, and traffichandling is a high-priority task for both telecom and datacommunicationsystems. However, fault recovery comprising handling of faults in thehardware, in the software or in a network has an even higher priority,while it is desirable that maintenance tasks, e.g. profiling, such ashardware testing and software consistency audits are prioritized with alower priority, since the collection of data should not be allowed todisturb the traffic. However, an additional drawback with theabove-described conventional profiling methods is that theimplementations may have a priority that is the same or even higher thanthe traffic. For example, instrumentation profiling inserts instructionsthat is executed as a part of the application and is therefore at thesame priority level as the application. Similarly, sampling profilingusing counters generates interrupts that are executed with a higherpriority than the traffic.

Thus, it still presents a problem to provide profiling in a real-timesystem with a high reliability, causing a profiling overhead that willnot overload the system.

SUMMARY

The object of the present invention is to address the problem outlinedabove, and this object and others are achieved by the method in a loadregulator and in a profiling tool, and by the load regulator andprofiling tool, according to the appended independent claims.

According to one aspect, the invention provides a method in a loadregulator of a system comprising a profiling tool, the load regulatorregularly monitoring the spare CPU capacity in said system. The loadregulator balances the profiling load with the spare CPU capacity in thesystem during profiling by regularly controlling the profilingperformance of the profiling tool using a communication interface tosaid profiling tool, and the method comprises the step of the loadregulator regularly informing the profiling tool of the spare CPUcapacity in the system during profiling.

By means of this balancing of the profiling load with the spare CPUcapacity in the system, the profiling tool will be able to use more ofthe total system capacity when the system has free CPU capacityavailable, enabling a more precise and/or a faster profiling result, andstill avoid overloading the system.

The method may comprise the further step of the load regulatorinstructing the profiling tool to gradually reduce the profilingperformance, if there is no spare CPU capacity in the system, and theload regulator may allow a profiling request from the profiling tool, ifthe system has spare CPU capacity. Additionally, the load regulator mayincrease the CPU-capacity, if there is no spare CPU capacity in thesystem.

According to another aspect, the invention provides a method in aprofiling tool of a system comprising a load regulator that regularlymonitors the CPU-load in said system. The profiling tool balances theprofiling load with the spare CPU capacity in the system by graduallyadjusting the profiling performance in response to information regardingavailable CPU capacity received regularly during profiling from the loadregulator over a communication interface.

The profiling performance may be adjusted in predetermined steps, andthe profiling tool may send regular updates to the load regulatorregarding an ongoing profiling activity.

Further, the profiling tool may request profiling allowance from theload regulator before increasing the profiling performance, and beforeinitiating a new profiling operation, which may have an unknown, or aguaranteed maximum, profiling overhead.

According to yet another aspect, the invention provides a load regulatorfor a system comprising a profiling tool, and the load regulatorcomprises an arrangement for regularly monitoring the spare CPU-capacityof the system. The load regulator is further provided with anarrangement for balancing the load of a profiling tool with the spareCPU capacity in the system during profiling, said arrangementcomprising:

-   -   An interface for communicating with the profiling tool;    -   A profiling controller capable of a controlling the profiling        performance of the profiling tool by regularly informing the        profiling tool of the spare CPU capacity in the system during        profiling.

The profiling controller may be arranged to instruct the profiling toolto gradually reduce the profiling performance, if there is no spare CPUcapacity in the system, or to instruct the profiling tool to terminatethe profiling.

Further, the profiling controller may be arranged to allow a profilingrequest from the profiling tool, if the system has spare CPU capacity,and to increase the CPU-capacity, if there is no spare CPU capacity inthe system.

According to still another aspect, the invention provides a profilingtool for a system comprising a load regulator arranged to regularlymonitor the spare CPU capacity of the system. The profiling tool isprovided with an arrangement for balancing the profiling load with thespare CPU capacity during profiling, said arrangement comprising:

-   -   An interface for communicating with the load regulator;    -   A profiling adjuster arranged to gradually adjust the profiling        performance in response to information received regularly from        the load regulator during the profiling

The profiling adjuster may be arranged to adjust the profilingperformance in predetermined steps, and to terminate the profiling.

The profiling adjuster may be further arranged to request allowance fromthe load regulator before initiating a new profiling operation, and thenew profiling operation may have an unknown, or a guaranteed maximum;profiling overhead.

Said profiling adjuster may be arranged to request allowance from theload regulator before increasing the profiling performance, and to sendregular updates to the load regulator regarding an ongoing profilingactivity.

Said profiling tool is arranged to perform e.g. sampling profiling orstatic or dynamic instrumentation profiling, or any combination thereof,and the gradual adjustment of the profiling performance may comprisee.g. a change of the sampling interval, a change of a dynamicinstrumentation, an insertion or a removal of an instrumentation pointor of a sampling event, or an early exit from a profiling routine.

Further, said spare CPU capacity may correspond to the differencebetween the maximum loadability and the total CPU load in the system.

BRIEF DESCRIPTION OF THE DRAWINGS

The present invention will now be described in more detail and withreference to the accompanying drawings, in which:

FIG. 1 is a block diagram schematically illustrating a profiling tool, aload regulator and the communication interface between them, accordingto this invention;

FIG. 2 a is a illustrates schematically the capacity levels in a system,while FIG. 2 b illustrates the capacity levels in said system duringprofiling;

FIG. 3 illustrates the program code in a dynamic instrumentationprofiling tool;

FIG. 4 is a signalling diagram illustrating an exemplary signallingsession between the profiling tool and the load regulator, according toan embodiment of the invention, and

FIG. 5 is a flow diagram illustrating the functions of the profilingtool and the load regulator, according to an exemplary embodiment ofthis invention.

DETAILED DESCRIPTION

In the following description, specific details are set forth, such asparticular arrangements and sequences of steps in order to provide athorough understanding of the present invention. However, it is apparentto a person skilled in the art that the present invention may bepractised in other embodiments that may depart from these specificdetails.

Moreover, it is apparent that the described functions may be implementedusing software functioning in conjunction with a programmedmicroprocessor or a general purpose computer, and/or using anapplication specific integrated circuit. Where the invention isdescribed in the form of a method, the invention may also be embodied ina computer program product, as well as in a system comprising a computerprocessor and a memory, wherein the memory is encoded with one or moreprograms that may perform the described functions.

This invention regularly and continuously balances the profiling toolperformance with the available CPU capacity in the system, during anentire profiling operation, and the invention involves providing aconventional load regulator for supervising the traffic load in a systemwith an additional functionality to regularly control the profilingperformance of a profiling tool in said system during profiling. Theprofiling tool is arranged to perform e.g. sampling profiling or staticor dynamic instrumentation profiling, or any combination thereof, and isfurther provided with an additional functionality to gradually reduce orincrease the profiling load by a suitable gradual adjustment of theprofiling operation in order to continuously balance the load of theprofiling overhead with the available CPU capacity in the system duringthe profiling, depending on the total CPU load of the profiling tool andof the other applications in the system.

Thus, a conventional load regulating function in a telecommunicationsystem controls and balances the traffic load with the availableresources, and when the load reaches the maximum loadability limit ofthe system, traffic may be rejected in order to avoid overload andrecovery procedures. According to this invention, a profiling balancingfunctionality is introduced in a load regulator and in a profiler,enabling communication between the load regulator and the profilerregarding the profiling operation during profiling. When there is nospare CPU capacity in the system, the load regulator will inform theprofiling tool that there is no spare capacity, or explicitly instructthe profiling tool to reduce the profiling load by a suitable adjustmentof the profiling operation in order to avoid overload. Alternatively, ifpossible, the load regulator will increase the available CPU capacity inthe system by steering the traffic and/or the profiling to anotheravailable. CPU, or instruct the CPU to increase its performance, i.e.the speed. Additionally, the load regulator will allow the profilingtool to increase the profiling performance when there is available spareCPU capacity in the system.

The introduced functionality of profiling balancing, according to thisinvention, may be divided into three functional parts, namely aprofiling adjusting function in the profiling tool, a profilingcontrolling function in the load regulator, and a communicationinterface. The profiling adjusting function in the profiling tool iscapable of “throttling” the profiling operation in order to graduallyreduce the profiling load and the capacity overhead resulting from theprofiling operation, with a capability to gradually increase theprofiling performance, if needed, if there is spare capacity in thesystem. The profiling controlling function in the load regulator iscapable of continuously balancing the profiling performance with theoverall CPU load in the system during an entire profiling operation bymonitoring of the spare CPU capacity of the system. The communicationinterface enables communication between the above-described profilingadjusting function in the profiler and the profiling controllingfunction in the load regulator, the interface comprising a profilingtool interface part and a load regulator interface part.

FIG. 1 illustrates schematically the three functional parts of thisinvention, showing a profiling tool 1, provided with a profilingadjusting functional unit, denoted profiling adjuster, 4, a loadregulator 2, provided with a profiling controlling functional unit,denoted profiling controller, 5, and the interface 3 enablingcommunication between the profiler and the load regulator, comprising aninterface part located in the profiling tool an interface part locatedin the load regulator.

By means of this introduced profiling balancing functionality, the loadregulator in a system will be able to prioritize between the traffichandling and the profiling, and the profiler will be allowed to use moreof the total system capacity, enabling a more precise and/or a fasterprofiling result, when the system has free CPU capacity available. Onthe contrary, when the system is heavily loaded, e.g. by external units,and the available capacity is limited, the load regulator may cause theprofiler to throttle the profiling, i.e. to gradually reduce theprofiling performance, in order to reduce the profile overhead to alevel that will not disturb or limit the traffic in the system. Ifpossible, the load regulator may steer traffic or profiling to anotheravailable CPU or increase the performance of the CPU, in order toincrease the available CPU capacity in the system.

When the total capacity used by the traffic and of the profiler reachesa predetermined maximum loadability level, the load regulator is able tostop the profiling operation completely, since the profiling balancingnormally prioritizes the traffic handling over the profiling. However,the load regulator will also allow the profiler to use more capacity forthe profiler, i.e. to gradually increase the profiling performance, whenthe CPU has spare capacity, in order to achieve a faster and/or a moreprecise profiling, if needed.

FIGS. 2 a and 2 b illustrates the level of the total CPU-capacity of asystem, denoted “Total capacity” in the figures, the traffic load,indicated by “Traffic”, the profiling load, i.e. the overhead caused bythe profiler, indicated by “Profiling” in the figures, the total load ofthe traffic and the profiling, indicated by the hatched line denoted“CPU Load”, the available free CPU-capacity, indicated by “SpareCapacity”, and the maximum loadability, which is indicated by thehatched line denoted “Max. loadability”. The FIG. 2 a shows the systembefore initiation of any profiling, and the FIG. 2 b shows the systemduring profiling. The spare capacity is regularly monitored duringprofiling by the conventional load regulating functionality of the loadregulator, and the spare CPU capacity in the system corresponds to thedifference between the maximum loadability and the total CPU load in thesystem. A conventional load regulator avoids traffic overload byrejecting traffic when the maximum loadability level of the system isreached, while a load regulator according to this invention also iscapable of continuously balancing the load of the profiling tool withthe traffic load and with the CPU capacity during a profiling operation.

A profiling adjusting function according to this invention may beintroduced e.g. in a sampling profiler, in a static instrumentationprofiler or in a dynamic instrumentation profiler, and theimplementation of the profiling adjustment will be different dependingon the profiler type. For example, if the load regulator would instructthe profiling adjusting function to turn the profiler off completely,the profiling adjusting function of a sampling profiler would maybedisable the sampling interrupts, while a static instrumentation profilerwould be switched to its non-instrumented version, and profilingadjusting function of a dynamic profiler would remove all profilingpoints.

A sampling profiler may “randomly” sample the execution to determinewhere time is spent, which addresses that generates cache misses, etc,and it may comprise a time counter and/or an event counter forgenerating interrupts for the collection of profiling data, the simplestsampling profiler being only a routine that is executed at the ordinaryperiodic clock interrupts. A more advanced sampling profiler enablingmore correct profiling data may use a separate timer for generatinginterrupts that are not synchronized with the clock interrupts, e.g.with a specific time interval or a specific number of events between theinterrupts. This may be a good approximation of random sampling, due tothe natural randomness of the program behaviour in a large communicationsystem.

According to a first exemplary embodiment, the added functionality ofthe profiling adjusting function in a sampling profiler is a binarythrottler, in which the profiling performance is reduced to zero bystopping the counter that generates the interrupts. In case of a clackinterrupt, the profile routine is removed from the tasks to be performedat a clock interrupt.

According to a second embodiment of the profiling adjusting function ina sampling profiler, the profiling performance is gradually reduced byan increase of the sampling interval, and the profiling performance isgradually increased by a reduction of the sampling interval, whichenables a stepwise control of the profiling load, e.g. in predeterminedsteps. Since the profiling load and the sampling interval are linearlycorrelated, the profiling load can be reduced by 50% by a doubling ofthe sampling interval. Preferably, the sampling interval can be changeddynamically during a measurement. In certain applications, the phasebehaviour changes over time, and a varying sampling rate may influencethe result, making dynamic changes of the sampling interval unsuitable.However, this is not the case in most communication and serverapplications, which typically has no, or only a limited, phasebehaviour.

According to a third embodiment of the profiling adjusting function in asampling profiler, the profiler is provided with an internal counter andis arranged to save profiling data at only a predetermined fraction ofthe interrupts. Thereby, the profiling load can be gradually reduced orincreased, e.g. in predetermined steps, but it can not be removedentirely.

Further exemplary embodiments of a profiling adjusting function in asampling profiler includes various combination of the above-describedembodiments, in order to achieve e.g. an initial gradual reduction ofthe profiling load using a profiling adjusting function according to thethird embodiment, but an eventual shut-dawn, if needed, e.g. by using aprofiling adjusting function according to the first embodiment.

A static instrumentation profiler is a separate, instrumented version ofthe program code, which is provided with added instructions for savingthe instrumentation data. The profiling adjusting function for a staticinstrumentation profiler enables switching between the instrumentedversion and the non-instrumented version, which means that the profilingis stopped completely. Another option in order to reduce the profilingperformance in a static instrumentation profiler is an early exit of aroutine.

In a dynamic instrumentation profiler, the profiling instrumentationcode is inserted dynamically, typically be means of replacing aninstruction in the code with a jump to a pre-reserved patch area. Inthis patch area, the instructions for the profiling are stored, as wellas for executing a replaced instruction, for restoring a state beforethe jump to the code area, and for jumping back. FIG. 3 illustrates aprogram code 8 and a patch area 9 in a dynamic instrumentation profiler,in which a jump instruction to the said patch area 9 is inserted in theinstrumentation point 7 of the program code 8.

A first embodiment of the profiling adjusting function for a dynamicinstrumentation profile is capable of removing instrumentation pointsdynamically, which may reduce the profiling performance gradually, oreven stop the profiling completely.

A second embodiment of the profiling adjusting function for a dynamicinstrumentation profiler comprises an internal counter, which saves theprofiling only a predetermined fraction of the times of the execution ofthe instructions in the patch area, and exits the routine the othertimes. A gradual reduction of the profiling performance, e.g. inpredetermined steps, as well as the resulting profiling load, isachieved by a reduction of the fraction, but the profiling will not beterminated completely. According to an exemplary embodiment, a separateinternal counter is provided for each instrumentation point, andaccording to another exemplary embodiment, a global counter is providedfor all instrumentation points, or for a group of points, which may beof a specific type.

An third embodiment of the profiling adjusting function for a dynamicinstrumentation profiler tool supports arbitrary actions in theinstrumentation points, which may comprise a conditional saving ofprofiling data when a user specific condition is fulfilled, or anentirely user programmable instruction, which is compiled and insertedin the instrumentation point.

A further embodiment of the profiling adjusting function for a dynamicinstrumentation profiler includes various combination of theabove-described embodiments, in order to achieve e.g. an initial gradualreduction of the profiling load using a profiling adjusting functionaccording to the second embodiment, but an eventual shut-down, ifneeded, by using a profiling adjusting function according to the firstembodiment.

Additionally, an early exit of a routine may be performed in a profilingadjusting function in a profiler tool of any type in order to reduce theprofiling performance, but the early exit normally results in a largerreduction of the profiling overhead during static and dynamicinstrumentation profiling than during sampling profiling.

The interface 3 between the profiling adjusting function in the profilertool and the profiling controlling function in the load regulatorcontrols the interaction between the load regulator and the profilingtool by enabling communication relating to the profiling performancebetween the profiler tool and the load regulator during profiling.According to an exemplary embodiment, the profiler tool sends regularupdates to the profiling controller in the load regulator regardingongoing profiling activities, and may also send profiling requests tothe load regulator before starting new profiling operations and beforeincreasing the profiling overhead from ongoing profiling operations, inorder to inform the load regulator that the profiling tool wants to usemore CPU capacity. If spare capacity is available, the load regulatorwill allow the profiling request, and will also send regular updates tothe profiler tool indicating any spare capacity, thereby enabling theprofiler tool to increase the profiling level in order to achieve e.g. amore detailed profiling.

FIG. 4 is a signalling diagram illustrating signalling between aprofiling tool 1 and a load regulator 2 regarding the profilingbalancing, according to an exemplary embodiment of this invention. Instep 4:1, the profiling tool sends a profiling request to the loadregulator, with an unknown capacity need. In step 4:2, the loadregulator responds by allowing the requested profiling and indicatingthat the spare capacity is 20%. The profiling tool will initiate theprofiling, and the load regulator regularly monitors the spare CPUcapacity during the profiling, and if detecting that no spare CPUcapacity is available, the load regulator sends a profiling reductioninstruction to the profiling tool, in step 4:3, and in step 4:4 the loadregulator indicates a spare capacity of 25% in the system after saidprofiling performance reduction. Thereafter, in step 4:5, the profilingtool requests an increase of the profiling performance again, and instep 4:6, the load regulator allows the request, and informs theprofiling tool that the spare capacity in the system presently is 20%.Finally, in step 4:7, the profiler informs the load regulator that theprofiling is terminated.

According to the exemplary embodiment illustrated in the signallingdiagram in FIG. 4, the profiling is launched with an unspecifiedcapacity need, and the profiler tool uses the information received fromthe load regulator to adjust the profiling performance to achieve anacceptable profiling load. This embodiment is suitable e.g. when theprofiler is a dynamic instrumentation profiler, in which the requiredprofiling capacity load may depend on how often a monitored event occursin a system.

According to a second embodiment, the profiling is launched with aguaranteed low profiling load, which is suitable e.g. for a samplingprofiler that can sample at a low default rate and increase the samplingrate based on information from the load regulator regarding availablecapacity.

FIG. 5 is a flow diagram illustrating another exemplary profilingbalancing procedure, and step 500 indicates the regular monitoring ofthe spare capacity in the system performed by the load regulator. Instep 502, the profiler tool sends a profiling requesting message to theload regulator, with an unknown or a guaranteed profiling overhead, andin step 504 the load regulator allows the profiling, and sends sparecapacity information to the profiler. In step 506, the profilerinitiates profiling according to the profiling request. The loadregulator regularly monitors any spare capacity, and when in step 508 itis determined that there is no spare CPU capacity available anymore,since the maximum loadability limit is reached, the load regulator sendsa message, in step 510, to the profiler that the profiling performancehas to be reduced. In step 512, the profiler gradually adjusts theprofiling performance by throttling the profiling operation in order toreduce the profiling performance, and in step 514, the load regulatorinforms the profiler of the spare capacity in the system after saidthrottling.

The described profiling balancing according to this invention enables amore detailed profiling regarding hardware and software parameters,thereby achieving a faster and more reliable evaluation of theperformance of new applications, based on real time systems. Sincemultiple workloads may be analysed, an improved knowledge can beobtained of detailed system characteristics with a real traffic mix.Further, system behaviour may be verified, lab results can be comparedwith live systems, and system configurations can be optimized, while animproved customer support is facilitated, as well as use of advanceddynamic profiling tools in real time systems with an improvedflexibility.

While the invention has been described with reference to specificexemplary embodiments, the description is in general only intended toillustrate the inventive concept and should not be taken as limiting thescope of the invention.

1-33. (canceled)
 34. A method in a load regulator of a system having aprofiling tool, the load regulator regularly monitoring spare CPUcapacity in the system and balancing a profiling load with the spare CPUcapacity in the system during profiling by regularly controlling theprofiling performance of the profiling tool using a communicationinterface to the profiling tool, the method comprising the steps of:receiving a profiling request from the profiling tool; determiningwhether the system has spare CPU capacity; allowing the profilingrequest if the system has spare CPU capacity; and regularly informingthe profiling tool of the spare CPU capacity in the system duringprofiling.
 35. The method according to claim 34, further comprisinginstructing the profiling tool to gradually reduce the profilingperformance, if there is no spare CPU capacity in the system.
 36. Themethod according to claim 34, further comprising increasing theCPU-capacity by the load regulator if there is no spare CPU capacity inthe system.
 37. A method in a profiling tool of a system having a loadregulator regularly monitoring a CPU-load in the system, wherein theprofiling tool balances profiling performance with spare CPU capacity inthe system during profiling, the method comprising the steps of:requesting a profiling allowance from the load regulator beforeincreasing the profiling performance; and gradually adjusting theprofiling performance in response to information regarding available CPUcapacity received regularly during profiling from the load regulatorover a communication interface.
 38. The method according to claim 37,wherein the step of gradually adjusting the profiling performanceincludes adjusting the profiling performance in predetermined steps. 39.The method according to claim 37, further comprising regularly sendingupdates from the profiling tool to the load regulator regarding anongoing profiling activity.
 39. The method according to claim 37,wherein the step of requesting a profiling allowance includes requestingthe profiling allowance from the load regulator before initiating a newprofiling operation.
 40. The method according to claim 39, wherein aninitiated new profiling operation has an unknown profiling overhead. 41.The method according to claim 39, wherein an initiated new profilingoperation has a guaranteed maximum profiling overhead.
 42. The methodaccording to claim 37, wherein the step of gradually adjusting theprofiling performance includes changing a sampling interval.
 43. Themethod according to claim 37, wherein the step of gradually adjustingthe profiling performance includes changing a dynamic instrumentation.44. The method according to claim 37, wherein the step of graduallyadjusting the profiling performance includes inserting or removing aninstrumentation point.
 45. The method according to claim 37, wherein thestep of gradually adjusting the profiling performance includes insertingor removing a sampling event.
 46. The method according to claim 37,wherein the step of gradually adjusting the profiling performanceincludes exiting early from a profiling routine.
 47. The methodaccording to claim 37, wherein the spare CPU capacity in the systemcorresponds to a difference between a maximum loadability and the totalCPU load of the system.
 48. A load regulator in a system having aprofiling tool, the load regulator for regularly monitoring spareCPU-capacity of the system and for balancing a load of the profilingtool with the spare CPU capacity in the system during profiling, saidload regulator comprising: an interface for communicating with theprofiling tool; a monitor for monitoring spare CPU-capacity of thesystem; a profiling controller for allowing a profiling request from theprofiling tool if the system has spare CPU capacity; and a profilingcontroller for controlling the profiling performance of the profilingtool by regularly informing the profiling tool of the spare CPU capacityin the system during profiling.
 49. The load regulator according toclaim 48, wherein the profiling controller includes means forinstructing the profiling tool to gradually reduce the profilingperformance if there is no spare CPU capacity in the system.
 50. Theload regulator according to claim 48, wherein the profiling controllerincludes means for instructing the profiling tool to terminate theprofiling when the total used CPU capacity reaches a predeterminedmaximum loadability level.
 51. The load regulator according to claim 48,wherein the profiling controller includes means for increasing theCPU-capacity if there is no spare CPU capacity in the system.
 52. Theload regulator according to claim 48, wherein the spare CPU capacitycorresponds to a difference between a maximum loadability and the totalCPU load in the system.
 53. A profiling tool in a system having a loadregulator for regularly monitoring spare CPU capacity of the system, theprofiling tool for balancing profiling performance with the spare CPUcapacity during profiling, said profiling tool comprising: an interfacefor communicating with the load regulator; a profiling adjuster forrequesting a profiling allowance from the load regulator beforeincreasing the profiling performance; and a profiling adjuster forgradually adjusting the profiling performance in response to informationreceived regularly from the load regulator during the profiling.
 54. Theprofiling tool according to claim 53, wherein the profiling adjusterincludes means for adjusting the profiling performance in predeterminedsteps.
 55. The profiling tool according to claim 53, wherein theprofiling adjuster includes means for terminating the profiling when thetotal used CPU capacity reaches a predetermined maximum loadabilitylevel.
 56. The profiling tool according to claim 53, wherein theprofiling adjuster includes means for requesting the profiling allowancefrom the load regulator before initiating a new profiling operation. 57.The profiling tool according to claim 56, wherein an initiated newprofiling operation has an unknown profiling overhead.
 58. The profilingtool according to claim 56, wherein an initiated new profiling operationhas a guaranteed maximum profiling overhead.
 59. The profiling toolaccording to claim 53, wherein the profiling adjuster includes means forregularly updating the load regulator regarding an ongoing profilingactivity.
 60. The profiling tool according to claim 53, wherein agradual adjustment of the profiling performance comprises a change ofthe sampling interval.
 61. The profiling tool according to claim 53,wherein a gradual adjustment of the profiling performance comprises achange of a dynamic instrumentation.
 62. The profiling tool according toclaim 53, wherein a gradual adjustment of the profiling performancecomprises an insertion or a removal of an instrumentation point.
 63. Theprofiling tool according to claim 53, wherein a gradual adjustment of aprofiling performance comprises an insertion or a removal of a samplingevent.
 64. The profiling tool according to claim 53, wherein a gradualreduction of a profiling performance comprises an early exit from aprofiling routine.
 65. The profiling tool according to claim 53, whereinthe spare CPU capacity corresponds to a difference between a maximumloadability and the total CPU load in the system.